<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ include file="/WEB-INF/view/common/talent-header.jspf" %>
	<div class="container">
	 	  <c:if test="${! empty msg }">
			<div class="alert alert-warning alert-dismissible fade in" role="alert">
			   <button type="button" class="close" data-dismiss="alert"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>
			   <strong>${msg }</strong>
			</div>
	 	 </c:if>
	 	</div>
<div style="width:500px;margin:100px auto">
	 <h1>求职者注册</h1>
	 <hr>
		<form class="form-horizontal" role="form" action="<%=request.getContextPath() %>/TalentServlet?command=add" method="post">
		  <div class="form-group">
		    <label for="code" class="col-sm-2 control-label">帐号：</label>
		    <div class="col-sm-10">
		      <input type="text" class="form-control" id="code" name="code" placeholder="请输入帐号（长度6~12）" data-rule="required;">
		    </div>
		  </div>
		  <div class="form-group">
			    <label for="password" class="col-sm-2 control-label">密码：</label>
			    <div class="col-sm-10">
			      <input type="password" class="form-control" id="password" name="password" placeholder="请输入密码（长度6~16）" data-rule="required;length(6~16)">
			    </div>
		  </div>
		  <div class="form-group">
			    <label for="password2" class="col-sm-2 control-label">确认密码：</label>
			    <div class="col-sm-10">
			      <input type="password" class="form-control" id="password2" name="password2" placeholder="请输入密码（长度6~16）" data-rule="确认密码: match(password);">
			    </div>
		  </div>
		   <div class="form-group">
			    <label for="name" class="col-sm-2 control-label">姓名：</label>
			    <div class="col-sm-10">
			      <input type="text" class="form-control" id="name" name="name" placeholder="请输入姓名" data-rule="required;">
			    </div>
		  </div>
		   <div class="form-group">
			    <label for="phone" class="col-sm-2 control-label">手机：</label>
			    <div class="col-sm-10">
			      <input type="text" class="form-control" id="phone" name="phone" placeholder="请输入手机号码" data-rule="required;">
			    </div>
		  </div>
		   <div class="form-group">
			    <label for="email" class="col-sm-2 control-label">email：</label>
			    <div class="col-sm-10">
			      <input type="text" class="form-control" id="email" name="email" placeholder="请输入email" data-rule="required;"> 
			    </div>
		  </div>
		   <div class="form-group">
			    <label for="age" class="col-sm-2 control-label">年龄：</label>
			    <div class="col-sm-10">
			    <select name="age" id="age" class="form-control" data-rule="required;">
					<option value="">-请选择-</option>
				</select>
			    </div>
		  </div>
			 <div class="form-group">
			    <label for="gender" class="col-sm-2 control-label">性别：</label>
			    <div class="col-sm-10">
			      <input type="radio" name="gender" value="1" checked="checked">男&nbsp;&nbsp;&nbsp;
			      <input type="radio" name="gender" value="2" >女
			    </div>
		  </div>
		  <div class="form-group">
			    <label for="hobby" class="col-sm-2 control-label">爱好：</label>
			    <div class="col-sm-10">
			     <input type="checkbox" name="hobby" value="看书">看书
				 <input type="checkbox" name="hobby" value="编程">编程
				 <input type="checkbox" name="hobby" value="旅游">旅游
				 <input type="checkbox" name="hobby" value="音乐">音乐
				 <span id="hobbyInfo"></span>
			    </div>
		  </div>
		   <div class="form-group">
		         <input type="text" name="validateCode" style="width:100px;height:35px;font-size: 18px;" maxlength="4" autocomplete="off">
		         <img src="GetCaptcha" alt="验证码" name="checkImg" id="checkImg" style="position:relative; top:5px; left:20px; " onClick="document.getElementById('checkImg').src='GetCaptcha?temp='+ (new Date().getTime().toString(36)); return false"/>
	         </div>
		  <div class="form-group">
		    <div class="col-sm-offset-2 col-sm-10">
		      <button type="submit" class="btn btn-info btn-lg">注册</button>
		    </div>
		  </div>
		</form>
	</div>
<%@ include file="/WEB-INF/view/common/footer.jspf"%>
<script>
window.onload=function(){
		 
		var s = document.getElementById("age");
		for (var i = 10; i <= 80; i++) {
			 var varItem = new Option(i, i);      
		        s.options.add(varItem); 
			}
	}
</script>